home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.ada,comp.lang.c,comp.lang.c++
- Path: netcom.com!adaworks
- From: adaworks@netcom.com (AdaWorks)
- Subject: Re: C/C++ knocks the crap out of Ada
- Message-ID: <adaworksDntn85.50y@netcom.com>
- Followup-To: comp.lang.ada,comp.lang.c,comp.lang.c++
- Organization: AdaWorks Software Engineering, Palo Alto, CA
- X-Newsreader: TIN [version 1.2 PL1]
- References: <JSA.96Feb16135027@organon.com>
- <4h8r0v$1c4i@saba.info.ucla.edu>
- <4hbj2b$cnt@sun152.spd.dsccc.com>
- <adaworksDnrqsE.LpC@netcom.com>
- <4hhred$1rn@sun152.spd.dsccc.com>
- Date: Wed, 6 Mar 1996 01:09:40 GMT
- Sender: adaworks@netcom19.netcom.com
-
- Kevin Cline (kcline@sun152.spd.dsccc.com) wrote:
-
- Kevin,
-
- First, thank you for this impressive enumeration of the difficulties
- you experienced. I realize, after re-reading my own posting, that it
- sounded a tad arrogant. My apologies.
-
- Neither I, nor anyone else, can really second-guess
- your findings with regard to the issues encountered on your project.
- I shall comment, briefly on some of them. Perhaps some of my colleagues
- will comment on others.
-
- : Well, I will now enumerate the difficulties I had porting an Ada program
- : with a Motif user interface from the TeleSoft compiler for Sparc-SunOS to
- : the Verdix compiler for MIPS/IRIX circa 1990:
-
- : 1. The TeleSoft compiler came with the IEEE Ada-POSIX bindings.
- : The Verdix compiler did not; instead it supported a Verdix-defined
- : API for UNIX services that was radically different.
-
- This was clearly a problem with early Ada implementations. Each
- software publisher chose a different approach to support for these
- bindings. Although this was an actual Ada language problem, it did
- represent poor coordination on this important problem.
-
- : 2. The syntax (pragmas) required to call C code from the two compilers
- : differed.
-
- Yes, I remember this. The pragma Interface was defined in way that
- encouraged deviation from the standard as well as the definition of
- entirely new pragmas such as pragma Interface_Name. Fortunately, this
- is corrected in the new Ada 95 standard.
-
- : 3. Although both compilers were 'validated', they both failed to compile
- : certain LRM-comformant code, and generated erroneous object code in
- : some other cases. I concluded that the Ada validation suite
- : was rather incomplete, and actually proved very little about compiler
- : quality.
-
- It sounds like this project used a very early version of an Ada
- compiler. Things did seem to improve somewhere in the 1989 time-frame.
-
- :
- : 4. The debuggers were extremely poor and buggy when compared to dbx.
- : In particular, the user interface to the Verdix debugger was one
- : of the most bizarre I have ever seen.
-
- Yes, some of the debuggers were horrible. In addition, some of the
- debuggers for competing languages were just as bad. In the current
- world of software practice, debuggers have gotten better for Ada and
- C, and C++, etc. It is sometimes tempting to evaluate older
- software technology in terms of what we have now.
-
- One amusing point. I recently heard someone say that Ada was so good
- that the requirement for a debugger was probably superfluous. It was
- difficult to stifle my laughter out of respect for the person making
- this observation. Of course we need good debuggers -- for all
- programming languages. I have recently seen some good progress in this
- area for Ada.
-
- : 6. Because Ada-83 did not allow passing procedures as parameters to
- : other procedures, there was no reasonable way to create an
- : API to an event-driven GUI library like MOTIF.
-
- No argument. As you know, this is fixed in Ada 95.
-
- : 5. The compilers had two completely different API's for calling
- : X and MOTIF services.
-
- No argument.
-
- : The lack of industry standard Ada bindings to these common OS
- : services combined with the high expense and poor quality of the
- : available Ada-83 compilers made development a medium-scale portable
- : UNIX application in Ada much more expensive and difficult than
- : developing the same application in C.
-
- I agree that this is an unresolved issue. However, serious work
- is in progress. With a little luck, it will get resolved.
-
- : Perhaps the emergence of GNAT has changed all this, but it is going
- : to be hard for Ada to keep up. To use Ada in my work today, I would
- : require an API to CORBA, Tcl/Tk, and the Solaris real-time facilities
- : (itimers, etc.) and a runtime that efficiently mapped Ada tasks to
- : Solaris threads.
-
- It is important to differentiate between GNAT, the compiler technology,
- and Ada 95, the language standard. Although GNAT is an excellent
- contribution to the advancement of Ada, other compilers are also in
- the works or already available.
-
- That being said, I know that some platforms have done a good job of
- mapping Ada tasks to Posix threads. In particular, the SGI Ada compiler,
- based on GNAT, has an excellent mapping to Ptrheads, which are, in turn,
- mapped to SPROCS, which in turn can be distributed across multiple
- processors. Also, SGI has mapped Ada to its standard debugging tools so
- Ada debugging on the SGI follows the same pattern as for any other
- language.
-
- I am not certain, but I think Sun still has a little work to do to make
- their Ada 95 development environment as robust as that on the SGI. CORBA
- and other bindings are underway, and we should see a little less
- confusion on this under the new Ada standard.
-
- After all of this, however, I stand by part of my earlier assertion that
- there were ways of improving the portability of Ada software, even under
- Ada 83. I know it took a long time and a lot of mistakes for many of us
- to figure out how to improve portability, so it wasn't always easy.
- Even so, your list of real-life difficulties is not trivial.
-
- Richard Riehle
- adaworks@netcom.com
- --
-
- richard@adaworks.com
- AdaWorks Software Engineering
- Suite 27
- 2555 Park Boulevard
- Palo Alto, CA 94306
- (415) 328-1815
- FAX 328-1112
-